package com.hhkj.admin.train.model.req;

import com.hhkj.admin.question.model.res.QuestionRes;
import com.hhkj.admin.train.common.cont.TrainConst;
import com.hhkj.admin.train.model.dopo.TrainDo;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;
import java.util.List;

/**
 * TrainReq
 *
 * @author ruoyi
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class TrainReq extends TrainDo
{

    public TrainReq(Long studentId,
                    Long courseId,
                    Long bankId,
                    List<QuestionRes> questionGroupList,
                    Date startTime)
    {
        this.setStudentId(studentId);
        this.setCourseId(courseId);
        this.setBankId(bankId);
        this.setStartTime(startTime);
        this.setTypeCode(TrainConst.Type.TEST.getCode());
        this.setQuestionGroupList(questionGroupList);
    }

    public TrainReq(Long studentId,
                    Long courseId,
                    Long bankId,
                    Integer totalAmount,
                    List<QuestionRes> questionGroupList,
                    Date startTime,
                    String practiceModeCode)
    {
        this.setStudentId(studentId);
        this.setCourseId(courseId);
        this.setBankId(bankId);
        this.setTotalAmount(totalAmount);
        this.setStartTime(startTime);
        this.setTypeCode(TrainConst.Type.PRACTISE.getCode());
        this.setPracticeModeCode(practiceModeCode);
        this.setQuestionGroupList(questionGroupList);
    }
}
